package com.zmn.plat.dubbo.impl.channel;

import com.zmn.common.dto2.ResponseDTO;
import com.zmn.plat.business.interfaces.channel.ChannelOrderConfigBService;
import com.zmn.plat.business.interfaces.channel.ChannelWorkOrderVideoBService;
import com.zmn.plat.dubbo.interfaces.channel.ChannelOrderConfigModifyRemoteService;
import com.zmn.plat.dubbo.utils.DubboConsts;
import com.zmn.plat.services.interfaces.channel.order.config.ChannelOrderConfigService;
import com.zmn.plat.services.interfaces.channel.workorder.picture.ChannelWorkOrderPictureService;
import lombok.extern.slf4j.Slf4j;
import org.apache.dubbo.config.annotation.DubboService;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;

/**
 * 描述: 渠道订单配置dubbo接口实现类
 *
 * @author jiafei
 * @since 2020/11/04 11:02
 */
@Slf4j
@DubboService(version = DubboConsts.INTERFACE_VERSION, validation = "true")
public class ChannelOrderConfigModifyRemoteServiceImpl implements ChannelOrderConfigModifyRemoteService {


    @Resource
    private ChannelOrderConfigBService channelOrderConfigBService;


    @Override
    public ResponseDTO<String> copy(Integer originalChannelId, Integer targetChannelId, String operator) {
        log.info("开始复制新渠道订单，原渠道id:{}，目标渠道id:{}", originalChannelId, targetChannelId);

        channelOrderConfigBService.copy(originalChannelId,targetChannelId,operator);

        return ResponseDTO.success("保存成功！");
    }

}
